
package com.zsrt.day20170504.ch06;

public class Test04 {

	public static void main(String[] args) {
		Ticket ticket = new Ticket(10);
		
		Buyer tick= new Buyer(ticket);
		
		Thread thread1 = new Thread(tick);
		Thread thread2 = new Thread(tick);
		thread1.setName("线程A");
		thread2.setName("线程B");
		
		thread1.start();
		thread2.start();
	}
	
}
